package com.yjd.comm.wal.service;

import java.util.List;
import java.util.Map;

import com.yjd.comm.base.service.IBaseService;
import com.yjd.comm.wal.dto.WalExtensionVo;
import com.yjd.comm.wal.model.WalAccountModel;
import com.yjd.comm.wal.model.WalExperienceProfitModel;

/**
 * <b>description</b>：小钱包体验金收益明细业务接口<br>
 * <b>time</b>：2015-09-15 11:04:45 <br>
 * <b>author</b>：  new
 */
public interface IWalExperienceProfitService extends IBaseService {
	/**
	 * 插入
	 * 
	 * @param model
	 * @return
	 * @throws Exception
	 */
	public WalExperienceProfitModel insert(WalExperienceProfitModel model) throws Exception;

	/**
	 * 更新,大于等于1表示成功，其他失败
	 * 
	 * @param model
	 * @return
	 * @throws Exception
	 */
	public int update(WalExperienceProfitModel model) throws Exception;

	/**
	 * 根据id删除,大于等于1表示成功，其他失败
	 * 
	 * @param id
	 * @return
	 * @throws Exception
	 */
	public int delete(Long id) throws Exception;
	
	/**
	 * 发放体验金利息
	 * @param user_id
	 * @param time
	 * @param accounts 用户的体验金列表
	 * @throws Exception
	 */
	void payExProfit(WalAccountModel wal, Long time ) throws Exception;
	
	/**
	 * receiveExperienceProfit:领取体验金. <br/> 
	 * 返回:boolean
	 * @exception
	 * @since JDK 1.7
	 */
	public boolean receiveExperienceProfit(Long userId)throws Exception;
	
	/**
	 * 统计体验金相关收益
	 * @param param
	 * @return
	 * @throws Exception
	 */
	public Double sumExperienceInterest(Map<String,Object> param)throws Exception;
	
	
	/**
	 * 统计
	* @param param
	* @return
	* @throws Exception
	* List<WalExtensionVo>
	 */
	public List<WalExtensionVo> getWalExtensionVo(Map<String,Object> paramMap) throws Exception;

}
